Skip to content

Unconditionally capture tokens for attributes.#77255

Merged
bors merged 4 commits intorust-lang:masterfrom
Aaron1011:feature/collect-attr-tokens
Oct 24, 2020
Merged

Unconditionally capture tokens for attributes.#77255
bors merged 4 commits intorust-lang:masterfrom
Aaron1011:feature/collect-attr-tokens

Conversation

@Aaron1011
Copy link
Copy Markdown
Contributor

This allows us to avoid synthesizing tokens in prepend_attr, since we
have the original tokens available.

We still need to synthesize tokens when expanding cfg_attr,
but this is an unavoidable consequence of the syntax of cfg_attr -
the user does not supply the # and [] tokens that a cfg_attr
expands to.

This is based on PR #77250 - this PR exposes a bug in the current collect_tokens implementation, which is fixed by the rewrite.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants